package com.woniu.humanresource.dao;


import com.woniu.humanresource.entity.JobRelation;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;


@Mapper
public interface JobRelationDao {
    //添加职位关系
    void insertJobRelation(JobRelation jobRelation);
    //查询所有职位关系
    List<JobRelation> selectAllJobRelation(@Param("pageIndex") int pageIndex,
                                           @Param("pageSize") int pageSize);
    //查询职位关系总条数
    int selectAllJobRelationcounts();
    //查询职位关系详细信息
    List<JobRelation> selectJobRelationByPosition(String position);
    //删除职位关系
    void deleteJobRelationByPosition(String position);
    //提交删除申请
    void deleteApplyByPosition(String position);
    //条件查询
    List<JobRelation> selectJobRelation(@Param("jobRelation") JobRelation jobRelation,
                                        @Param("pageIndex") int pageIndex,
                                        @Param("pageSize") int pageSize);
    //条件查询总条数
    int selectJobRelationCounts(@Param("jobRelation") JobRelation jobRelation);
    //修改职位关系
    void updateJobRelation(@Param("jobRelation") JobRelation jobRelation,
                           @Param("position") String position);
}
